home *** CD-ROM | disk | FTP | other *** search
/ Softwarová Záchrana 3 / Softwarova-zachrana-3.bin / Xteq X-Setup / xqdcXSP-Setup-EN.exe / {app} / plugins / XQ Logoff Pictures.xpl < prev    next >
Text File  |  2001-01-21  |  2KB  |  79 lines

  1. "FILE"="Xteq Systems X-Setup Plugin 6.0"
  2. "TYPE"="3"
  3. "COUNT"="2"
  4. "UIPATH 1"="Startup/Shutdown\Shutdown\Windows 9x/ME\30) Power Off"
  5. "NAME"="Windows 9x/ME Logoff Pictures"
  6. "VERSION"="1.47"
  7. "OSVERSION"="10101"
  8. "LANGUAGE"="VBScript"
  9. "TEXT 1"="Picture 1"
  10. "TEXT 2"="Picture 2"
  11. "DATA 1"="Bitmap picturs (*.BMP)|*.bmp"
  12. "DATA 2"="Bitmap picturs (*.BMP)|*.bmp"
  13. "DESCRIPTION 1"="This plug-in can be used to change the pictures that are displayed when logging off from Windows."
  14. "DESCRIPTION 2"=""Picture 1" is displayed while the computer is shut down (Please wait while...)."
  15. "DESCRIPTION 3"=""Picture 2" is displayed when the computer can be turned off (It's safe now to...)."
  16. "DESCRIPTION 4"="NOTE #1: Both pictures should be 320x400 pixels with 256 colors."
  17. "DESCRIPTION 5"="NOTE #2: Both settings are for Windows 9x or Windows Me."
  18. "AUTHOR"="Xteq Systems"
  19. "CONTACTURL"="http://www.xteq.com"
  20. "COPYRIGHT"="Copyright ⌐ Xteq Systems - All Rights Reserved"
  21. "COMMENT 1"=" "
  22. "COMMENT 2"="Thanks to John [hartjenj@earthlink.net] for the bug report!"
  23.  
  24. Sub Plugin_Initialize 
  25.     'SetUIElement 1,GetWinDir
  26.     'SetUIElement 2,GetWinDir
  27.     SetUIElement 1,"C:\"
  28.     SetUIElement 2,"C:\"
  29. End Sub
  30.  
  31. Sub Plugin_CheckData(ElementIndex)
  32. End Sub
  33.  
  34. Sub Plugin_Apply(ElementIndex,ElementSubIndex)
  35.  s=GetUIElement(1)
  36.  if len(s)>3 then
  37.   Call DoWork("LOGOW.SYS","LOGOW.XSB",s)
  38.   Call Restart
  39.  end if
  40.  
  41.  s=GetUIElement(2)
  42.  if len(s)>3 then
  43.   Call DoWork("LOGOS.SYS","LOGOS.XSB",s)
  44.   Call Restart
  45.  end if
  46.  
  47.  Call MsgInformation("The new logo has been set.")
  48. End Sub
  49.  
  50. Sub Plugin_Terminate 
  51. End Sub
  52.  
  53.  
  54. Sub DoWork(File1,BackupFile,NewFile)
  55.  s1=GetWinDir & File1
  56.  s2=GetWinDir & BackupFile
  57.  s3=NewFile
  58.  
  59.  'if backup exists, delete it
  60.  if FileExists(s2) then
  61.   Call FileSetAttribute(s2,"S-")
  62.   Call FileSetAttribute(s2,"R-")
  63.   Call FileSetAttribute(s2,"H-")
  64.   Call FileDelete(s2)
  65.  end if
  66.  
  67.  'make backup of current file
  68.  if FileExists(s1) then
  69.   Call FileSetAttribute(s2,"S-")
  70.   Call FileSetAttribute(s2,"R-")
  71.   Call FileSetAttribute(s2,"H-")
  72.   Call FileCopy(s1,s2)
  73.   Call FileDelete(s1)
  74.  end if
  75.  
  76.  'now copy new file to old file
  77.  Call FileCopy(s3,s1)
  78. End Sub
  79.